<link type="text/css" rel="stylesheet" href="_testing/style.css" />
<style>
    #who{
        display:none;
    }
    table.center td{
        text-align: center;
    }
</style>

<script type="text/javascript" src="_testing/jquery.js"></script>
<script type="text/javascript" src="_testing/script.js"></script>
<script>
    $(function(){
        $("#who_click > .Person").each(function(){
            $(this).click(function(){
                $('#who').show();
            })
        });
    });
</script>
<div class="ChooseSpec" style="min-height:600px;">
    <div class="h1">
        Кто ты?
    </div>
    <div class="persons" id="who_click" style="height:102px;overflow: hidden;">
        <div class="Person">
            <img src="img/spec_icons/programmer-icon.gif"><br>
            Разработчик
        </div>
        <div class="Person">
            <img src="img/spec_icons/programmer_icon.jpg"><br>
            Дизайнер
        </div>
        <div class="Person">
            <img src="img/spec_icons/programmer-icon.gif"><br>
            Тестировщик
        </div>
        <div class="Person">
            <img src="img/spec_icons/programmer_icon.jpg"><br>
            Менеджер
        </div>
        <div class="Person">
            <img src="img/spec_icons/programmer-icon.gif"><br>
            Аналитик
        </div>
        <div class="PersonWho orange">
            <img src="img/spec_icons/q.png"><br>
            Я не определился
        </div>
    </div>


    <div class="cloud" id="who">
        <div class="h2 center">
            Кем хочешь быть?
        </div>
        <table class="center" style="width:100%;">
            <?php
              foreach ( $spec_tests as $row ) {
                  ?>

                  <tr>
                      <td style="padding:20px;">
                          <div class="h2 center">
                              <?php echo $row['name'] ?> 
                          </div>
                      </td>
                      <?php
                      foreach ( $row['spec'] as $spec ) {
                          ?>
                          <td>
                              <div class="Person">
                                  <a href="<?php echo $spec['link'] ?>">
                                      <img src="<?php echo $spec['img'] ?>"><br>
                                      <?php echo $spec['name'] ?>
                                  </a>

                              </div>
                          </td>
                          <?php
                      }
                      ?>
                  </tr>
                  <?php
              }
            ?>
        </table>
    </div>
</div>

